<!--
 * @Description: 前缀列表的详情
 * @Author: 0001101008/HuYuxi
 * @Date: 2021-11-02 15:15:02
 * @LastEditTime: 2021-11-05 10:33:52
 * @LastEditors: 0001100986/LiuShuai
-->
<template>
  <table class="backbone-info">
    <template v-if="row.items.length > 0">
      <tr v-for="(it, key) in row.items" :key="key">
        <td>前缀IP</td>
        <td>{{it.addr ? it.addr : '-'}}</td>
        <td>下限-上限</td>
        <td>{{it.gt}} - {{it.lt}}</td>
        <td>动作</td>
        <td>{{it.permit ? 'Permit': 'Deny'}}</td>
      </tr>
    </template>
    <template v-else>
      <tr>
        <td>暂无数据</td>
      </tr>
    </template>
  </table>
</template>

<script>
export default {
  props: ['row']
};
</script>

<style lang="scss" scoped>
.backbone-info {
  width: 100%;
  border: 1px solid #ebeef5;
  tr {
    width: 100%;
    td {
      padding: 5px 15px;
      line-height: 30px;
      &:first-child {
        width: 170px;
        text-align: center;
        background: #f8f8f9;
      }
      &:nth-child(3) {
        width: 170px;
        text-align: center;
        background: #f8f8f9;
      }
    }
  }
}
</style>